<!DOCTYPE HTML>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<meta http-equiv="pragma" content="no-cache" />
		<meta http-equiv="Content-Language" content="zh-CN" />
		<style>
			.enty-editor {height:400px;border:1px solid;}
			.box {width:800px;margin:0 auto;}
			.ex {margin:24px 0;}
		</style>
		<link href="style/css/editor.css" type="text/css" rel="stylesheet" />
		<link href="style/css/panel.css" type="text/css" rel="stylesheet" />
		<script>
			if(window.console) {
				window.console = {};
				window.console.log = function(){};
			}
		</script>
	</head>
	<body>
		<div class="box">
			<div class="pro_tools" id="testSaveButtons"></div>
			<div id="frame" class="enty-editor">
				<textarea id="frameToText" class="se_textarea"></textarea>
			</div>
		</div>
		<script type="text/javascript" src="sinaeditor_min.js"></script>
		<script>
			var href = window.location.href;
			var loc = href.substring(0,href.lastIndexOf('/'));
			var textCSS = loc+'/style/css/contents.css';
			window.onload = function(){
				var config = {
					"id": "myEditor",
					//编辑器的按钮存放的base dom id 或者dom
					"toolBase": 'testSaveButtons',
					"initType": {
						"name": "initFromStatic",
						"args": {
							"parent": document.getElementById('frame')
						}
					},
					//可选
					"filter": {
						"name": "pasteFilter",
						"args": {
							"tagName": "SCRIPT|INPUT|IFRAME|TEXTAREA|SELECT|BUTTON",
							"noFlashExchange": false,
							"attribute": "id"
						}
					},
					"editorName": 'SinaEditor._.entyimpl.normalEditor',
					"styles": "body {\
									margin:0px;\
									padding:0px;\
									width:100%;\
									height:100%;\
								}\
								.biaoqing {\
									width:22px;\
									height:22px;\
								}",
					"styleLinks": [textCSS],
					"plugns": [{
						"name": "addContent"
					},{
						"name": "showSource",
						"args": {
							"entyArea": document.getElementById('frameToText')
						}
					},
					{
						"name": "link"
					},{
						"name": "backcolor"
					},
					{
						"name": "forecolor"
					}, {
						"name": "underline"
					},{
						"name": "italic"
					}, {
						"name": "bold"
					}, {
						"name": "linkBubble"
					}, {
						"name": "imgBubble"
					}, {
						"name": "flashBubble"
					}, {
						"name": "redoManager"
					}, {
						"name": "fontFamily"
					}, {
						"name": "fontSize"
					}, {
						"name": "markList"
					}, {
						"name": "numberList"
					}, {
						"name": "indent"
					}, {
						"name": "outdent"
					}, {
						"name": "justifyright"
					}, {
						"name": "justifycenter"
					}, {
						"name": "justifyleft"
					}, {
						"name": "imgUI"
					}, {
						"name": "flashUI"
					}, {
						"name": "tableUI"
					}, {
						"name": "faceUI"
					},{
						"name": "historyUI",
						"args" : {
							"id" : 1
						}
					}]
				};
				window.editor1 = SinaEditor.createEditor(config);
			}
		</script>
	</body>
</html>